# Maintainer: Fabian Bornschein <fabiscafe-at-mailbox-dot-org>
# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>

pkgname=gnome-clocks
pkgver=45.0
pkgrel=1
pkgdesc="Clocks applications for GNOME"
url="https://wiki.gnome.org/Apps/Clocks"
arch=(loong64 x86_64)
license=(GPL)
depends=(
  geoclue
  geocode-glib-2
  gnome-desktop-4
  gtk4
  libadwaita
  libgweather-4
  xdg-desktop-portal
)
makedepends=(
  git
  gobject-introspection
  meson
  vala
  yelp-tools
)
groups=(gnome)
_commit=b1c6ff122488fea47833108f7f661481b9b9574a  # tags/45.0^0
source=("git+https://gitlab.gnome.org/GNOME/gnome-clocks.git#commit=$_commit")
b2sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/[^-]*-g/r&/;s/-/+/g'
}

prepare() {
  cd $pkgname
}

build() {
  arch-meson $pkgname build
  meson compile -C build
}

check() {
  meson test -C build --print-errorlogs
}

package() {
  meson install -C build --destdir "$pkgdir"
}

# vim:set sw=2 sts=-1 et:
